import 'package:flutter/material.dart';
import 'package:honeypotflutter/publicBussine/bussine_colors.dart';
import 'package:honeypotflutter/publicBussine/bussine_font.dart';

class CabinetListInfoTitle extends StatelessWidget {
  const CabinetListInfoTitle({super.key});

  @override
  Widget build(BuildContext context) {
    return Flex(
      direction: Axis.horizontal,
      children: [
        customWidget(title: "编号"),
        customWidget(flex: 3, title: "指导快递员"),
        customWidget(flex: 2, title: "激活状态"),
        customWidget(title: "操作"),
      ],
    );
  }

  Widget customWidget({required String title, int flex = 1}) {
    return Expanded(
      flex: flex,
      child: Container(
        padding: EdgeInsets.only(top: 15, bottom: 15),
        decoration: BoxDecoration(
          border: Border.all(color: MGColors.splitColor, width: 0.5),
          color: MGColors.backColor.withOpacity(0.5),
        ),
        child: Text(
          title,
          textAlign: TextAlign.center,
          style: TextStyle(color: MGColors.text2Color, fontSize: MGFont.textFont3),
        ),
      ),
    );
  }
}
